home *** CD-ROM | disk | FTP | other *** search
/ Sprite 1984 - 1993 / Sprite 1984 - 1993.iso / src / lib / tcl / dist6.3 / porting.notes < prev    next >
Encoding:
Text File  |  1992-04-01  |  4.7 KB  |  131 lines

  1. This file contains a collection of notes that various people have
  2. provided about porting Tcl to various machines and operating systems.
  3. I don't have personal access to any of these machines, so I make
  4. no guarantees that the notes are correct, complete, or up-to-date.
  5. In some cases, a person has volunteered to act as a contact point
  6. for questions about porting Tcl to a particular machine;  in these
  7. cases the person's name and e-mail address are listed.
  8.  
  9. ---------------------------------------------
  10. Cray machines running UNICOS:
  11. Contact: John Freeman (jlf@cray.com)
  12. ---------------------------------------------
  13.  
  14. 1. The nm command on unicos doesn't have a -p option, so I removed it
  15. from the config script without apparent harm.
  16.  
  17. diff -c -r1.1 config
  18. *** 1.1    1991/11/12 15:11:51
  19. --- config    1991/11/12 15:14:18
  20. ***************
  21. *** 57,63 ****
  22.       echo "  to set the libc variable."
  23.       exit(1)
  24.   endif
  25. ! nm -p $libc > tmp.libc
  26.   if ( $status != 0 ) then
  27.       echo "- ERROR\!\!  Nm failed to extract names of system-supplied library"
  28.       echo "  procedures from $libc.  You'll have to modify config by hand to"
  29. --- 57,63 ----
  30.       echo "  to set the libc variable."
  31.       exit(1)
  32.   endif
  33. ! nm $libc > tmp.libc
  34.   if ( $status != 0 ) then
  35.       echo "- ERROR\!\!  Nm failed to extract names of system-supplied library"
  36.       echo "  procedures from $libc.  You'll have to modify config by hand to"
  37.  
  38. 2. There is an error in the strstr function in UNICOS such that if the
  39. string to be searched is empty (""), the search will continue past the
  40. end of the string.  Because of this, the history substitution loop
  41. will sometimes run past the end of its target string and trash
  42. malloc's free list, resulting in a core dump some time later.  (As you
  43. can probably guess, this took a while to diagnose.)  I've submitted a
  44. problem report to the C library maintainers, but in the meantime here
  45. is a workaround.
  46.  
  47. -----------------------------------------------------------------
  48. diff -c1 -r1.1 tclHistory.c
  49. *** 1.1    1991/11/12 16:01:58
  50. --- tclHistory.c    1991/11/12 16:14:22
  51. ***************
  52. *** 23,24 ****
  53. --- 23,29 ----
  54.   #include "tclInt.h"
  55. + #ifdef _CRAY
  56. + /* There is a bug in strstr in UNICOS; this works around it. */
  57. + #define strstr(s1,s2) ((s1)?(*(s1)?strstr((s1),(s2)):0):0)
  58. + #endif _CRAY
  59.  
  60.  
  61. ---------------------------------------------
  62. HP-UX systems:
  63. ---------------------------------------------
  64.  
  65. 1. The #define for TCL_UNION_WAIT in tclUnix.h needs to be set to 0,
  66. not 1.  I've tried a number of techniques to get the "config" script
  67. to figure this out and set it correctly, but so far I haven't been
  68. able to make it work for HP-UX systems.
  69.  
  70. 2. It may also be useful to add the flag "-D_BSD" to CFLAGS in the
  71. Makefile, but I'm not sure this is necessary (and it may even be
  72. evil) if TCL_UNION_WAIT has been #define'd correctly.
  73.  
  74. ---------------------------------------------
  75. MIPS systems runing EP/IX:
  76. ---------------------------------------------
  77.  
  78. 1. Need to add a line "#include <bsd/sys/time.h>" in tclUnix.h.
  79.  
  80. 2. Need to add "-lbsd" into the line that makes tclTest:
  81.  
  82.     ${CC} ${CFLAGS} tclTest.o libtcl.a -lbsd -o tclTest
  83.  
  84. ---------------------------------------------
  85. IBM RS/6000 systems running AIX:
  86. ---------------------------------------------
  87.  
  88. 1. The system version of strtoul is buggy, at least under some
  89. versions of AIX.  If the expression tests fail, try forcing Tcl
  90. to use its own version of strtoul instead of the system version.
  91. To do this, first copy strtoul.c from the compat subdirectory up
  92. to the main Tcl directory.  Then modify the Makefile so that
  93. the definition for COMPAT_OBJS includes "strtoul.o".  Note:  the
  94. "config" script should now detect the buggy strtoul and substitute
  95. Tcl's version automatically.
  96.  
  97. 2. You may have to comment out the declaration of open in tclUnix.h.
  98.  
  99. 3. The "nm -p ..." line in the file "config" has to be changed to
  100. "nm -en ..." if you use the version of nm that's in /bin.  If you're
  101. set up to use the BSD version (in /usr/ucb) then this won't be a
  102. problem.
  103.  
  104. ---------------------------------------------
  105. AT&T 4.03 OS:
  106. ---------------------------------------------
  107.  
  108. Machine: i386/33Mhz i387 32k Cache 16MByte 
  109. OS: AT&T SYSV Release 4 Version 3
  110. X: X11R5 fixlevel 9
  111. Xserver: X386 1.2
  112.  
  113. 1. Change the Tk Makefile as follows:
  114. XLIB            = -lX11
  115.     should be changed to:
  116. XLIB            = -lX11 -lsocket -lnsl
  117.  
  118. 2. Change the Tcl "config" script as follows:
  119. set libc="/lib/libc.a"
  120.     should be changed to:
  121. set libc="/usr/ccs/lib/libc.a"
  122.  
  123. -------------------------------------------------------
  124. Motorola MPC's running UNIX System V/88 Release R32V2:
  125. -------------------------------------------------------
  126.  
  127. 1.  Tcl should build without any modifications to sources, but csh
  128. isn't supplied with the operating system so you'll have to find and
  129. use the public-domain tcsh.
  130.